home *** CD-ROM | disk | FTP | other *** search
- bat * working * (to be used with ANSI.SYS device driver in DOS 2.0)
- bat goto -start
- bat -field %o = 0
- bat type %l %a %l ;
- bat inkey %1 | %0 = %1 # | if %0 = 1 skip 5
- bat if %1 = key009 %n = %n + 1 | return
- bat if %1 = key10f %n = %n - 1 | return
- bat if %1 = key00d %o = 1 | return
- bat if %1 = key01b cls | exit
- bat beep | goto -field
- bat %a = %1
- bat type %lk ;
- bat skip 11
- bat -fielda inkey %1 | %0 = %1 # | if %0 = 1 skip 9
- bat if %1 = key009 %n = %n + 1 | return
- bat if %1 = key10f %n = %n - 1 | return
- bat if %1 = key00d %o = 1 | return
- bat if %1 = key01b cls | exit
- bat if %1 <> key008 beep | goto -fielda
- bat %0 = %a # | if %0 = 0 beep | goto -fielda
- bat %0 = %0 - 1 | %a = %a $ 1 %0
- bat type %lk %a ;
- bat goto -fielda
- bat %a = %a%1
- bat %0 = %a # | type %l %a ;
- bat if %0 < %m goto -fielda
- bat %n = %n + 1 | return
- bat -menu cls
- bat begtype
-
- FORMAT
-
- File:
-
- Pages:
-
- To:
-
- Left margin override:
-
- Pause at page-break :
- end
- bat type 6H %c
- bat type 3H %d
- bat type 31H %e
- bat type 31H %f
- bat %a =
- bat -field1 %n = 1 | %l = 6H
- bat %a = %b | %m = 14 | call -field
- bat %b = %a | if %o = 0 goto -field%n
- bat goto -process
- bat -field2 %n = 2 | %l = 6H
- bat %a = %c | %m = 14 | call -field
- bat %c = %a | if %o = 0 goto -field%n
- bat goto -process
- bat -field3 %n = 3 | %l = 3H
- bat %a = %d | %m = 1 | call -field
- bat %d = %a $ 1 1
- bat if .%d = .s %d = screen | skip 2
- bat if .%d = .p %d = printer | skip 1
- bat %d = screen | beep | goto -field3
- bat type %l %d | if %o = 0 goto -field%n
- bat goto -process
- bat -field4 %n = 4 | %l = 31H
- bat %a = %e | %m = 2 | call -field
- bat %e = %a | if %o = 0 goto -field%n
- bat goto -process
- bat -field5 %n = 5 | %l = 31H
- bat %a = %f | %m = 1 | call -field
- bat %f = %a $ 1 1
- bat if .%f = .n %f = no | skip 2
- bat if .%f = .y %f = yes | skip 1
- bat %f = no | beep | goto -field5
- bat type %l %f | if %o = 0 goto -field%n
- bat goto -process
- bat -field0 goto -field1
- bat -field6 goto -field5
- bat -start %b =
- bat %c = 1-99
- bat %d = Screen
- bat %e = NO
- bat %f = NO
- bat %0 = %1 # | if %0 = 0 goto -menu
- bat %b = %1
- bat -parse %1 = %2 | %2 = %3 | %3 = %4 | %4 = %5 | %5 = %6 | %6 = %7 | %7 =
- bat %0 = %1 # | if %0 = 0 goto -process
- bat if %1 = printer %d = printer | goto -parse
- bat if %1 = screen %d = screen | goto -parse
- bat if %1 = pause %f = yes | goto -parse
- bat %0 = %1 $ 1 5 | if %0 <> pages skip 2
- bat %c = %2 | %1 = %2 | %2 = %3 | %3 = %4
- bat %4 = %5 | %5 = %6 | %6 = | goto -parse
- bat %0 = %1 $ 1 4 | if %0 <> left skip 2
- bat %e = %2 | %1 = %2 | %2 = %3 | %3 = %4
- bat %4 = %5 | %5 = %6 | %6 = | goto -parse
- bat type syntax error: %1
- bat type use:
- bat type format file screen/printer pages=nn left=nn pause
- bat exit
- bat -process %0 = %b # | if %0 <> 0 skip 2
- bat cls | type filename is required
- bat inkey hit any key to continue ... | goto -menu
- bat stateof %b | if %r <> 9 skip 2
- bat cls | type invalid file name: %b
- bat %b = | inkey hit any key to continue ... | goto -menu
- bat if %r <> 1 skip 2
- bat cls | type file %b not found
- bat inkey hit any key to continue ... | goto -menu
- bat %0 = %b # | %1 = %b $ %0 1 | if .. = .%1 %0 = %0 - 1 | %b = %b $ 1 %0
- bat cls
- bat type %%b = file = %b
- bat type %%c = pages = %c
- bat type %%d = dest = %d
- bat type %%e = lmo = %e
- bat type %%f = pause = %f
- bat if %d = screen %d = | skip 1
- bat %d = -de.dvc
- bat if %c = 1-99 %c = | skip 1
- bat %c = -s%c
- bat if %e = no %e = | skip 1
- bat %e = -o%e
- bat if %f = no %f = | skip 1
- bat %f = -p
- bat stack rem wordix %d %c %e %f %b
-